home *** CD-ROM | disk | FTP | other *** search
- Copyright (c) 1988 Thomas G. Hanlin III
- VIDCLOCK.COM v1.1 09/11/88
- A configurable background-operating time display utility
-
-
- VIDCLOCK keeps a constant time display on the screen. You can select the
- location the time will be displayed, what color it will be, whether it
- will be normal or military (24-hour) format, whether the seconds should be
- displayed, whether flicker-free video is required, and how often to update
- the display. You can also remove VIDCLOCK entirely from memory if you so
- desire. For help, just type VIDCLOCK without any parameters.
-
-
-
- This utility may be freely distributed according to these rules:
-
- 1) VIDCLOCK.COM, VIDCLOCK.DOC, and VIDCLOCK.NEW must be distributed
- together, in unmodified form.
-
- 2) No fee may be charged, other than a disk duplication / handling fee
- which may not exceed $10.00.
-
-
-
- VIDCLOCK Options:
-
- /I Install the clock (turns on the clock)
-
- /R Remove the clock (turns off the clock)
-
- /F Flicker-free (slow) video, for cheap CGAs
-
- /M Military time format (24-hour clock)
-
- /S Seconds off (don't display seconds)
-
- /C=f,b Color settings for clock. Foreground and background colors are
- selectable, using numbers as follows:
-
- Number Color system
- 0 Black
- 1 Blue
- 2 Green
- 3 Cyan
- 4 Red
- 5 Magenta
- 6 Brown
- 7 White
-
- Add eight to foreground for intense or bright colors.
- Add eight to background for blinking colors (not recommended).
-
- For a Monochrome display, use the following pairs:
- Numbers Mono System
- 7,0 Normal
- 1,0 Underlined
- 0,7 Inverse video
-
- /L=r,c Location of clock. Row and Column should be specified. The
- upper left corner of the screen is 1,1. The default is around
- 1,71 (depending on screen mode and /F, /S options). It is
- recommended that the clock go on the top line of the screen, or
- past the 25th line (for EGA/VGA in the proper modes), since
- normal scrolling will otherwise tend to messily duplicate the
- time value on the screen.
-
- /U=t Update frequency: how often to update the clock display, in
- 18ths of seconds. This may range from 1-255, with the default
- at 9 (update every half-second).
-
-
-
- General Information:
-
- VIDCLOCK is designed to work with any text-mode screen. It will work on
- Monochrome, CGA, EGA, VGA, and Hercules displays. Any text mode can be
- used: 40x25, 80x25, 80x43, 80x50. Only IBM and compatible machines are
- supported-- if it doesn't work, your computer isn't compatible enough.
-
- VIDCLOCK is a TSR (Terminate and Stay Resident) program. It takes up a
- tiny 608 bytes of memory until you remove it or reboot the computer.
-
- The /F option should only be used if VIDCLOCK causes flickering on your
- screen (which will only happen on some low-quality CGAs). It will stop
- the flickering, at the cost of some speed. It will also tend to cause
- interference with any serial communications being done.
-
- The /U option controls how frequently the clock display is updated, in
- 18ths of seconds. Smaller values restore the clock faster if it is erased
- from the screen (by scrolling, CLS, or whatever), but also result in more
- interference with communications and so forth. Larger values will cause a
- greater delay in restoring the clock if it is erased, and may result in an
- unevenly-updated clock. The default is 9, or an update once every half
- second. This may be decreased to 1 (beware of interference with
- communications) or increased to 255 (values over 18 are only recommended
- if you turn off the "seconds" display using /S, or are using a display
- line greater than 25).
-
-
-
- Technical Notes:
-
- There are a lot of TSR clocks like this in existence. Many of them are
- poor... some of them are pretty good... VIDCLOCK was designed to be better!
-
- There are three major constraints for a program such as VIDCLOCK:
-
- 1) It needs to be small. It's a TSR, and occupies system memory until
- told to remove itself. Optimization for size is important.
-
- 2) It needs to be efficient. It hooks into the system timer interrupt,
- and careless handling can cause the entire system to slow down.
- Interference with fast interrupt-driven events, such as communications,
- is also possible. Optimization for speed is vital.
-
- 3) It needs to be flexible. People have different types of displays, and
- require different time formats. Configurability is the touch that lets
- a single program suit many different needs.
-
- VIDCLOCK is designed to fulfill these constraints as best as possible.
-
- VIDCLOCK correctly handles any normal text screen mode. It does so on a
- static basis, going by what was in effect when it was installed. Any
- display may be used, with any display page (if applicable), in 40x25,
- 80x25, 80x43, and 80x50 text modes on MDA, Hercules, CGA, EGA, and VGA
- systems. It is assumed that screen flicker or "snow" is not a problem,
- since that's true in most cases, and it makes for much faster displays.
- Flicker-free display techniques can be selected manually if required.
-
- VIDCLOCK's copy of the environment space is discarded before installation,
- to keep the size to a minimum. VIDCLOCK can detect whether it has been
- installed, in a manner resistant to disruption by other TSRs. When
- VIDCLOCK is turned off, it restores the original interrupt vectors and
- removes itself from memory. In operation, VIDCLOCK uses direct machine
- access for speed and to avoid the reentrancy problem with BIOS and DOS.
-
- The timer interrupt INT 8 is used to tell when to update the clock. This
- reduces likelihood of conflict with other TSRs, which tend to use INT 1Ch
- for timing purposes. The actual time is calculated from the BIOS time
- data area. Interrupt INT 2Fh (the "multiplex" interrupt) is also hooked
- in, for use in determining whether the clock is installed and in removing
- the clock. The VIDCLOCK device identifier is 0DAh. You can use the
- following method to see if VIDCLOCK is installed (assembly language):
-
- MOV AX,0DA00h ; query status for I.D. 0DAh
- INT 2Fh ; use multiplex interrupt
- ;-------------------------
- ; Returns:
- ; AL=0 not installed
- ; AL=0FFh installed
-